package com.kedacom.general.param;

import java.util.List;

public class ServiceParam {

    /**
     * messageId : d63873b6779042eebcbde0b8613e27b6
     * version : 1.0
     * parameter : {"dataObjId":"czrk","regionalismCode":"","networkCode":"","condition":{"logicalOperate":"and","keyValueList":[{"key":"name","relationOperator":"=","value":"'张三'"},{"key":"age","relationOperator":">","value":"20"}]},"fields":"name,age","orderBy":[{"orderbyField":"name","sort":"desc"},{"orderbyField":"age","sort":"asc"}],"page":{"pageSize":1,"pageNo":1}}
     */

    private String messageId;
    private String version;
    private ParameterBean parameter;

    public String getMessageId() {
        return messageId;
    }

    public void setMessageId(String messageId) {
        this.messageId = messageId;
    }

    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public ParameterBean getParameter() {
        return parameter;
    }

    public void setParameter(ParameterBean parameter) {
        this.parameter = parameter;
    }

    public static class ParameterBean {
        /**
         * dataObjId : czrk
         * regionalismCode :
         * networkCode :
         * condition : {"logicalOperate":"and","keyValueList":[{"key":"name","relationOperator":"=","value":"'张三'"},{"key":"age","relationOperator":">","value":"20"}]}
         * fields : name,age
         * orderBy : [{"orderbyField":"name","sort":"desc"},{"orderbyField":"age","sort":"asc"}]
         * page : {"pageSize":1,"pageNo":1}
         */

        private String dataObjId;
        private String regionalismCode;
        private String networkCode;
        private ConditionBean condition;
        private String fields;
        private PageBean page;
        private List<OrderByBean> orderBy;

        public String getDataObjId() {
            return dataObjId;
        }

        public void setDataObjId(String dataObjId) {
            this.dataObjId = dataObjId;
        }

        public String getRegionalismCode() {
            return regionalismCode;
        }

        public void setRegionalismCode(String regionalismCode) {
            this.regionalismCode = regionalismCode;
        }

        public String getNetworkCode() {
            return networkCode;
        }

        public void setNetworkCode(String networkCode) {
            this.networkCode = networkCode;
        }

        public ConditionBean getCondition() {
            return condition;
        }

        public void setCondition(ConditionBean condition) {
            this.condition = condition;
        }

        public String getFields() {
            return fields;
        }

        public void setFields(String fields) {
            this.fields = fields;
        }

        public PageBean getPage() {
            return page;
        }

        public void setPage(PageBean page) {
            this.page = page;
        }

        public List<OrderByBean> getOrderBy() {
            return orderBy;
        }

        public void setOrderBy(List<OrderByBean> orderBy) {
            this.orderBy = orderBy;
        }

        public static class ConditionBean {
            /**
             * logicalOperate : and
             * keyValueList : [{"key":"name","relationOperator":"=","value":"'张三'"},{"key":"age","relationOperator":">","value":"20"}]
             */

            private String logicalOperate;
            private List<KeyValueListBean> keyValueList;

            public String getLogicalOperate() {
                return logicalOperate;
            }

            public void setLogicalOperate(String logicalOperate) {
                this.logicalOperate = logicalOperate;
            }

            public List<KeyValueListBean> getKeyValueList() {
                return keyValueList;
            }

            public void setKeyValueList(List<KeyValueListBean> keyValueList) {
                this.keyValueList = keyValueList;
            }

            public static class KeyValueListBean {
                /**
                 * key : name
                 * relationOperator : =
                 * value : '张三'
                 */

                private String key;
                private String relationOperator;
                private String value;

                public String getKey() {
                    return key;
                }

                public void setKey(String key) {
                    this.key = key;
                }

                public String getRelationOperator() {
                    return relationOperator;
                }

                public void setRelationOperator(String relationOperator) {
                    this.relationOperator = relationOperator;
                }

                public String getValue() {
                    return value;
                }

                public void setValue(String value) {
                    this.value = value;
                }
            }
        }

        public static class PageBean {
            /**
             * pageSize : 1
             * pageNo : 1
             */

            private int pageSize;
            private int pageNo;

            public int getPageSize() {
                return pageSize;
            }

            public void setPageSize(int pageSize) {
                this.pageSize = pageSize;
            }

            public int getPageNo() {
                return pageNo;
            }

            public void setPageNo(int pageNo) {
                this.pageNo = pageNo;
            }
        }

        public static class OrderByBean {
            /**
             * orderbyField : name
             * sort : desc
             */

            private String orderbyField;
            private String sort;

            public String getOrderbyField() {
                return orderbyField;
            }

            public void setOrderbyField(String orderbyField) {
                this.orderbyField = orderbyField;
            }

            public String getSort() {
                return sort;
            }

            public void setSort(String sort) {
                this.sort = sort;
            }
        }
    }
}
